﻿using MCMesServer.DBFunctions.TransformFuncs;
using MesBLL.EventService;
using MesDAL.DBInfo;
using MesDAL.DTO.NetSetting;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace MCMesServer.DBFunctions.DBFuncs
{
    public class EquipNetSettingInfoDBFunc
    {
        public async static Task<List<EquipNetSettingDTO>> GetEquipNetSettingInfoList()
        {
            using (var ser = new EquipNetSettingService())
            {
                List<EquipNetSettingDTO> EquipNetSetting_List = new List<EquipNetSettingDTO>();
                List<equipnetsetting_info> info_list = await ser.SelectAllEquipNetSetting();
                for (int i = 0; i < info_list.Count; i++)
                {
                    EquipNetSetting_List.Add(TransformDTOFunc.TransformModel2EquipNetSettingDTO(info_list[i]));
                }
                return EquipNetSetting_List;
            }
        }
    }
}
